#ifndef mW_pathfinding_include
#define mW_pathfinding_include

#include <stdlib.h>
#include <string.h>
#include "list.h"
#include "map.h"
#include "minheap.h"



#define mW_PATHFINDING_MOVEMENT_COST 10



typedef struct _mW_pathfinding_point
{
	
	int x;
	int y;
	int g;
	int h;
	struct _mW_pathfinding_point * parent_point;
	
} mW_pathfinding_point;


mW_list *              mW_pathfinding_find_path (mW_map * map, int start_x, int start_y, int end_x, int end_y);
int                    mW_pathfinding_calculate_heuristic (int start_x, int start_y, int end_x, int end_y);
mW_pathfinding_point * mW_pathfinding_point_create (int x, int y, int g, int h, mW_pathfinding_point * parent);
int                    mW_pathfinding_compare (mW_pathfinding_point * one, mW_pathfinding_point * two);
mW_pathfinding_point * mW_pathfinding_point_copy (mW_pathfinding_point * source);
int                    mW_pathfinding_point_exists (mW_list * set, int x, int y);
mW_pathfinding_point * mW_pathfinding_point_from_list (mW_list * set, int x, int y);
int                    mW_pathfinding_search_function (void * one, void * two);
int                    mW_pathfinding_neighbor (mW_map * map, int x, int y, int end_x, int end_y, mW_pathfinding_point * current_point, mW_minheap * openset, mW_list * closedset);


#endif // mW_pathfinding_include
